@mixin nav($navbg,$fontsize,$height:40px,$padding:30px,$bg:#333,$dsheight:0px,$dswidth:2px,$dsbg:red,$ioheight:0px,$iowidth:14px,$iobg:red){
    height: $height;
    background: $navbg;
    li{
        list-style: none;
        height: $height;
        display: inline;
        float:left;
        font-size: $fontsize;
        vertical-align: top;
       
        a{
            display: inline-block;
            $padding_top : ($height - $fontsize)/2; 
            height: $height - $padding_top;
            padding: $padding_top $padding 0;
            vertical-align: top;
            
        }
        a.active,a:hover{
            background: $bg;
        }
        @if $dsheight != '0px' {
            i.ds{
              font-size: 0;
              display: inline-block;
              line-height: $dsheight;
              height: $dsheight;
              width: $dswidth;
              margin-right: -$dswidth;
              top: ($height - $dsheight)/2;
              left: -($dswidth/2);
              background: $dsbg;
              position: relative;
              z-index: 1000;
            }          
        }

        @if $ioheight != '0px' {
            i.ico{
                font-size: 0;
                display: inline-block;
                line-height: $ioheight;
                height: $ioheight;
                width: $iowidth;
                margin-right: -$iowidth;
                top: ($height - $ioheight)/2;
                left: $padding - $iowidth - 4px;
                background: $iobg;
                position: relative;
                z-index: 1000;
            }
        }
    }
}


@mixin nav-border($navbg,$fontsize,$height:40px,$padding:12px,$bg:#333,$navbc:#333,$itembc:#ccc,$dsheight:0px,$dswidth:2px,$dsbg:red,$ioheight:0px,$iowidth:14px,$iobg:red){
    height: $height;
    background: $navbg;
    border-bottom: 1px solid $navbc;
    height: $height + 1px;
    li{
        list-style: none;
        height: $height;
        display: inline;
        float:left;
        font-size: $fontsize;
        vertical-align: top;
       
        a{
            display: inline-block;
            $padding_top : (($height - $fontsize)/2)-1px; 
            height: $height - $padding_top;
            padding: $padding_top $padding 0;
            vertical-align: top;
            
        }
        a.active,a:hover{
            background: $bg;
            border-bottom: 2px solid $navbc;
            _position: relative;
            _top:1px;
            _margin-top: -1px;
        }
        @if $dsheight != '0px' {
            i.ds{
              font-size: 0;
              display: inline-block;
              line-height: $dsheight;
              height: $dsheight;
              width: $dswidth;
              margin-right: -$dswidth;
              top: ($height - $dsheight)/2;
              left: -($dswidth/2);
              background: $dsbg;
              position: relative;
              z-index: 1000;
            }          
        }

        @if $ioheight != '0px' {
            i.ico{
                font-size: 0;
                display: inline-block;
                line-height: $ioheight;
                height: $ioheight;
                width: $iowidth;
                margin-right: -$iowidth;
                top: ($height - $ioheight)/2;
                left: $padding - $iowidth - 4px;
                background: $iobg;
                position: relative;
                z-index: 1000;
            }
        }
    }
}

